package cn.sdhuijin.model;

import java.io.Serializable;
import java.util.List;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * @author sunp@sdhuijin.cn:
 * @version 创建时间：2015年4月29日 上午10:51:24 类说明
 */

@Entity
@Table(name = "standardfolder")
public class StandardFolder extends IdEntity implements Serializable {

	private static final long serialVersionUID = 1L;

	private String name;

	private double score;

	private boolean safeManager;

	@ManyToOne
	private Standard standard;

	@OneToMany(cascade = { CascadeType.ALL }, mappedBy = "standardFolder", fetch = FetchType.LAZY)
	private List<StandardItem> standardItems;

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name
	 *            the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @return the score
	 */
	public double getScore() {
		return score;
	}

	/**
	 * @param score
	 *            the score to set
	 */
	public void setScore(double score) {
		this.score = score;
	}

	/**
	 * @return the safeManager
	 */
	public boolean isSafeManager() {
		return safeManager;
	}

	/**
	 * @param safeManager
	 *            the safeManager to set
	 */
	public void setSafeManager(boolean safeManager) {
		this.safeManager = safeManager;
	}

	/**
	 * @return the standardItems
	 */
	public List<StandardItem> getStandardItems() {
		return standardItems;
	}

	/**
	 * @param standardItems
	 *            the standardItems to set
	 */
	public void setStandardItems(List<StandardItem> standardItems) {
		this.standardItems = standardItems;
	}

	/**
	 * @return the standard
	 */
	public Standard getStandard() {
		return standard;
	}

	/**
	 * @param standard
	 *            the standard to set
	 */
	public void setStandard(Standard standard) {
		this.standard = standard;
	}

}
